import Vue from 'vue';
import VueRouter from 'vue-router';
import routes from './routerData';
Vue.use(VueRouter);

const router = new VueRouter({
  mode: 'history',
  base: process.env.VUE_APP_PUBLIC_PATH,
  routes: [
    ...routes,
    {
      path: '*',
      component: () => import(/* webpackChunkName: "404" */ '@/views/app/404.vue'),
      meta: {
        title: '404',
      },
    },
  ],
});

export default router;
